import request from '@/utils/request'

// 查询服务商体现审核列表
export function listWithdraw(query) {
  return request({
    url: '/finance/withdraw/list',
    method: 'get',
    params: query
  })
}

// 查询服务商体现审核详细
export function getWithdraw(id) {
  return request({
    url: '/finance/withdraw/' + id,
    method: 'get'
  })
}

// 新增服务商体现审核
export function addWithdraw(data) {
  return request({
    url: '/finance/withdraw',
    method: 'post',
    data: data
  })
}

// 修改服务商体现审核
export function updateWithdraw(data) {
  return request({
    url: '/finance/withdraw',
    method: 'put',
    data: data
  })
}

// 删除服务商体现审核
export function delWithdraw(id) {
  return request({
    url: '/finance/withdraw/' + id,
    method: 'delete'
  })
}

// 审核通过
export function updateWithdrawApply(data) {
  return request({
    url: '/finance/withdraw/pass/' + data,
    method: 'put',
    headers: {
      'Content-Type': 'application/json'
    }
  })
}

// 审核拒绝
export function refuseWithdraw(data) {
  return request({
    url: '/finance/withdraw/reject/'+ data,
    method: 'put'
  })
}